deps: Update dependency pyrefly to >=0.62.0,<0.63#715
Merged
renovate[bot] merged 1 commit intomainfrom May 5, 2026
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
>=0.61.1,<0.62→>=0.62.0,<0.630.63.1(+1)Release Notes
facebook/pyrefly (pyrefly)
v0.62.0: Pyrefly v0.62.0Compare Source
Status : BETA
Release date: April 20, 2026
Pyrefly v0.62.0 bundles 87 commits from 23 contributors.
✨ New & Improved
TypeVarTupleinference has been changed to be consistent withTypeVar, per a recent change to the typing spec.- Errors logged during speculative union checks and overload calls are now reverted, eliminating a source of confusing false positives.
- Union-typed decorators that return fully unknown types (either
Unknownor callables with all-unknown signatures) preserve the original function signature instead of replacing it withUnknown, reducing false positives by ~23% on TensorFlow.inmemory://documents on Windows.- LSP server crashes from out-of-range line numbers in client requests are prevented by clamping positions to the buffer's valid range.
- Invariance checks for mutable attributes (corresponding to mypy's
mutable-overrideopt-in behavior) have been moved to a newbad-override-mutable-attributeerror code that is a sub-kind ofbad-override.- The
bad-param-name-overrideerror has been renamed tobad-override-param-nameand made a sub-kind ofbad-override.- Sub-configs that define
[errors]inherit the root config's error severity overrides for any codes they don't explicitly set.pyrefly init,bad-override-mutable-attributeis disabled by default to match mypy's behavior.- Project excludes (e.g.,
project-excludes = ["**/*.ipynb"]) no longer block discovery of.pyfiles when the defaultproject-includescontains both**/*.py*and**/*.ipynb.🐛 bug fixes
We closed 12 bug issues this release 👏
types-python-dateutilfor thedateutilmodule, nottypes-dateutil) by extracting the module→package mapping from the bundled typeshed archive, preventing potential typosquatting.NewType("NewNoneType", NoneType)is now accepted as a valid nominal type declaration, and plainNoneis correctly rejected whereNewNoneTypeis required.unexpected-keyworderrors for named parameters before*args: P.args. Functions likecall_with_retry(f, max_attempts=10, *args: P.args, **kwargs: P.kwargs)now correctly allowmax_attemptsto be passed as a keyword argument, matching mypy and pyright behavior.DidChangeTextDocumentrace where the file was truncated). Out-of-range positions now map to EOF instead of panicking.bad-argument-typeforlist(null_values.items())when the return type hint is a union likeSequence[str] | list[tuple[str, str]]. Pyrefly now tries constructing the class with each union member independently and unions the results, ensuring the inferred type is assignable to the hint.bad-argument-typewhen calling a method withAnyStr. Placeholder variables used during overload resolution are now saved and restored around overload calls, preventingAnyStrfrom being incorrectly specialized tostrand polluting subsequent checks.invalid-type-varfor generic functions captured as closure default arguments. TheVisitimplementation forDefaultValuenow callsvisitinstead ofrecurse, ensuring type-level visitors see theTypenode stored in the default value..valueon enum members with non-data-type mixins. Mixins that don't define__new__(e.g.,class Meta: pass) are no longer treated as data type mixins, soFoo.bar.valuecorrectly returnsLiteral[1]instead ofMeta.bad-argument-typefor overloaded functions with vararg unpacking (e.g.,*args: *tuple[int, str]). Type check errors for unpacked varargs are now sent tocall_errorsinstead ofarg_errors, so they don't cause the overload to be incorrectly rejected.bad-specializationwhen matching a type variable against a union likeN | Iterable[N]. Pyrefly now uses snapshot-based rollback when trying each union member, ensuring specialization errors from one branch don't leak into the final result if another branch succeeds without errors.Thank-you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
📦 Upgrade
How to safely upgrade your codebase
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
1.
pyrefly check --suppress-errors2. run your code formatter of choice
3.
pyrefly check --remove-unused-ignores4. Repeat until you achieve a clean formatting run and a clean type check.
This will add
# pyrefly: ignorecomments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.Read more about error suppressions in the Pyrefly documentation
🖊️ Contributors this release
@rchen152, @stroxler, @migeed-z, @jorenham, @samwgoldman, @connernilsen, @NathanTempest, @kinto0, @jvansch1, @fangyi-zhou, @tejasreddyvepala, David Tolnay, generatedunixname2066905484085733, @mstykow, @AHA705, @Arths17, @grievejia, Claudionor Santos, @austin3dickey, @robertoaloi, @salvatorebenedetto, @iamPulakesh, generatedunixname89002005307016
Please note: These release notes summarize major updates and features. For brevity, not all individual commits are listed. Highlights from patch release changes that were shipped after the previous minor release are incorporated here as well.
Configuration
📅 Schedule: (UTC)
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.